package pantallas;
import java.awt.Dimension;
import java.awt.Toolkit;

import javax.swing.DefaultComboBoxModel;
import javax.swing.JButton;
import javax.swing.JList;
import javax.swing.JScrollPane;
import javax.swing.JTable;
import javax.swing.ListModel;
import javax.swing.WindowConstants;
import javax.swing.table.DefaultTableModel;
import javax.swing.table.TableModel;
import javax.swing.SwingUtilities;


/**
* This code was edited or generated using CloudGarden's Jigloo
* SWT/Swing GUI Builder, which is free for non-commercial
* use. If Jigloo is being used commercially (ie, by a corporation,
* company or business for any purpose whatever) then you
* should purchase a license for each developer using Jigloo.
* Please visit www.cloudgarden.com for details.
* Use of Jigloo implies acceptance of these licensing terms.
* A COMMERCIAL LICENSE HAS NOT BEEN PURCHASED FOR
* THIS MACHINE, SO JIGLOO OR THIS CODE CANNOT BE USED
* LEGALLY FOR ANY CORPORATE OR COMMERCIAL PURPOSE.
*/
public class utilizarReservaView extends javax.swing.JFrame {
	private JScrollPane jScrollPane1;
	private JTable tResrevas;
	private JButton cmdCancelar;
	private JButton cmdAceptar;

	/**
	* Auto-generated main method to display this JFrame
	*/
	public static void main(String[] args) {
		SwingUtilities.invokeLater(new Runnable() {
			public void run() {
				utilizarReservaView inst = new utilizarReservaView();
				inst.setLocationRelativeTo(null);
				inst.setVisible(true);
			}
		});
	}
	
	public utilizarReservaView() {
		super();
		initGUI();
	}
	
	private void initGUI() {
		try {
			setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
			getContentPane().setLayout(null);
			pack();
			this.setSize(400, 221);
			setTitle("Utilizar Reserva");
			{
				jScrollPane1 = new JScrollPane();
				getContentPane().add(jScrollPane1);
				jScrollPane1.setBounds(12, 12, 368, 129);
				{
					TableModel tResrevasModel = 
							new DefaultTableModel(
									new String[][] { 	{ "Ramiro", "20:30", "5" }, 
														{ "Julio", "21:45", "2" } },
									new String[] { "Nombre", "Hora", "Cubiertos" });
					tResrevas = new JTable();
					jScrollPane1.setViewportView(tResrevas);
					tResrevas.setModel(tResrevasModel);
					tResrevas.setPreferredSize(new java.awt.Dimension(350, 106));
				}
			}
			{
				cmdAceptar = new JButton();
				getContentPane().add(cmdAceptar);
				cmdAceptar.setText("Aceptar");
				cmdAceptar.setBounds(12, 161, 127, 21);
			}
			{
				cmdCancelar = new JButton();
				getContentPane().add(cmdCancelar);
				cmdCancelar.setText("Cancelar");
				cmdCancelar.setBounds(254, 161, 127, 21);
			}
			//MEDIDAS Y CENTRALIZACION DE LA PANTALLA.
	        Dimension dim = Toolkit.getDefaultToolkit().getScreenSize();
	        int w = this.getSize().width;
	        int h = this.getSize().height;
	        int x = (dim.width-w)/2;
	        int y = (dim.height-h)/2;
	        this.setLocation(x, y);
		} catch (Exception e) {
		    //add your error handling code here
			e.printStackTrace();
		}
	}

}
